# This is a sample Python script.

# Press Shift+F10 to execute it or replace it with your code.
# Press Double Shift to search everywhere for classes, files, tool windows, actions, and settings.
import pandas as pd


def read_emails_from_excel(file_path):
    # 读取Excel文件
    df = pd.read_excel(file_path)

    # 假设邮箱地址在名为 'Email' 的列中
    emails = df['Email'].tolist()
    return emails


def simulate_user_actions(emails):
    for email in emails:
        print(f"Processing email: {email}")

        # 模拟获取验证码
        verification_code = input("Enter the verification code sent to your email: ")

        # 模拟勾选所有授权
        agree_terms = input("Do you agree to all terms and conditions? (yes/no): ").strip().lower()
        if agree_terms == 'yes':
            print("All terms and conditions have been agreed.")
        else:
            print("You must agree to all terms and conditions to proceed.")
            continue

        # 模拟用户名输入
        username = input("Enter your username: ").strip()

        # 这里可以添加更多的逻辑，比如保存数据到数据库或调用API等
        print(f"User {username} has been processed with email {email}.")


if __name__ == "__main__":
    excel_file_path = "emails.xlsx"  # 替换为你的Excel文件路径
    emails = read_emails_from_excel(excel_file_path)
    simulate_user_actions(emails)
